package com.yingxin.yxerp.module.dingtalk.entity.enums;

import org.apache.commons.lang3.StringUtils;

public enum WeComUserStatus {

    ONE("1", "全职"),
    TWO("2", "实习"),
    THREE("3", "其他");

    private String status;

    private String statusName;

    WeComUserStatus(String status, String statusName) {
        this.status = status;
        this.statusName = statusName;
    }

    public String getStatus() {
        return status;
    }

    public void setStatus(String status) {
        this.status = status;
    }

    public String getStatusName() {
        return statusName;
    }

    public void setStatusName(String statusName) {
        this.statusName = statusName;
    }

    public static WeComUserStatus getEnum(String status) {
        if( StringUtils.isNotBlank( status ) ){
            return null;
        }
        for (WeComUserStatus i : WeComUserStatus.values()) {
            if ( i.getStatus().equals( status ) ) {
                return i;
            }
        }
        return null;
    }

}
